import request from './request';

export function getPaymentList(params) {
  return request({
    url: '/payment',
    method: 'get',
    params
  });
}

export function createPayment(data) {
  return request({
    url: '/payment/pay',
    method: 'post',
    data
  });
}

export function queryPayment(paymentNo) {
  return request({
    url: `/payment/query/${paymentNo}`,
    method: 'get'
  });
}

export function refundPayment(data) {
  return request({
    url: '/payment/refund',
    method: 'post',
    data
  });
}
